﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Speech.Recognition;
using System.Threading;
using grounding.parser;
using grounding.parser.Parsers;

namespace grounding.tests.TemplateRecognizerTest
{
    class Program
    {
        static void Main(string[] args)
        {
            DemoActionParser parser = new DemoActionParser();
            string input;
            while ((input = Console.ReadLine().ToLower()) != "exit")
            {
                DemoActionTemplate template = (DemoActionTemplate)parser.Parse(input);

                if (template == null)
                    Console.WriteLine("Unrecognized sentence");
                else
                {
                    foreach (string option in template.info.Keys)
                    {
                        Console.WriteLine("template[" + option + "]=" + template.info[option]);
                    }
                }
            }
        }
    }
}
